package com.aube.plugin.guide;

import android.graphics.Point;
import android.graphics.Rect;

import com.aube.plugin.guide.Target;

/**
 * Created by mertsimsek on 25/01/16.
 */
public class DoubleRect {

    private Target target, main;

    private Rect rectShape, mainRect;

    private Point circlePoint;

    public DoubleRect(Target target, Target main) {
        this.target = target;
        this.main = main;
        circlePoint = getFocusPoint();
        rectShape = getRectShape();
        mainRect = getMainRect();
    }

    private Point getFocusPoint(){
        return target.getPoint();
    }

    private Rect getRectShape() {
        return target.getRect();
    }

    private Rect getMainRect() {
        return main.getRect();
    }

    public void reCalculateAll(){
        rectShape = getRectShape();
        mainRect = getMainRect();
    }

    public Rect getRect() {
        return rectShape;
    }

    public Rect getMain() {
        return mainRect;
    }

    public Point getPoint(){
        return circlePoint;
    }

}
